/**
 * Copyright (c) 2016-2019 人人开源 All rights reserved.
 *
 * https://www.renren.io
 *
 * 版权所有，侵权必究！
 */

package com.qywx.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.qywx.entity.SysUserEntity;
import com.qywx.entity.TagEntity;
import com.qywx.entity.UserEntity;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Component;

import java.util.HashMap;
import java.util.List;
import java.util.Set;

/**
 * @ClassName UserDao
 * @Description: 用户
 * @Author wmj
 * @Date 2020/3/2
 * @Version V1.0
 **/
@Mapper
@Component
public interface UserDao extends BaseMapper<UserEntity> {

	//根据用户名查询用户
	List<UserEntity> findByName(String name,int depid,String id,String category,String gender);

	//根据部门id查询部门成员
	List<UserEntity> findByDepartmentId(int depid,int start,int size,String status);

	String getTotal(String departmentId,String status);

    void exchangeDepartment(String departmentId, String userid);

	String asynchronousDetection();

	List<UserEntity> synchronize();

    List<UserEntity> export(String depid);

	UserEntity selectDetailById(String userid);

	String findNameById(String id);

	List<TagEntity> getTagName(String userid);

	List<UserEntity> findUser(int start, int size);

	//String getTotal();

	String getTotalAll();

	List<String> findUserId(String depid);

	List<UserEntity> exportByUserId(String userid,String usertype);

	Integer findDepartByDepName(String depName);

    void saveTagUser(long tagId, String userid);

	void deleteBatchId(List<String> list);

	void updateStatus(String userid);

    String getMobile(String mobile);

    void saveDepUser(int depart,String userid);

	List<String> findByUserid(String userid);

	void deleteDepUser(String userid);

	List<String> findDepartmentId(String userid);

    void delUserDep(List<String> list);

	List<Integer> selDepIdByUserid(String userid);

	void updateStat(String userid);

	List<String> findAllUser();

	List<UserEntity> findByNameAll(String name,String usertype,String stat,String status,String id,String category,String gender);

	List<UserEntity> findUserWai(int start, int size);

	String getTotalAllWai();

	List<UserEntity> findUserCondition(int start, int size, String stat, String status);

	String getTotalAllCondition(String stat,String status);

	List<UserEntity> findUserWaiCondition(int start, int size, String stat);

	String getTotalAllWaiCondition(@Param("stat") String stat);

    int selByUseridAndDepid(String userid, int depid);

	void updateStat1(String userid);

	void delUserTad(String userid);

	void batchUpdate(List<String> list);

	//List<UserEntity> selectBatchId(List<String> list);
}
